package com.fenghen.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.fenghen.system.mapper.RiskReportMapper;
import com.fenghen.system.domain.RiskReport;
import com.fenghen.system.service.IRiskReportService;
import com.fenghen.common.core.text.Convert;

/**
 * 风险报告模块Service业务层处理
 * 
 * @author fenghen
 * @date 2024-11-06
 */
@Service
public class RiskReportServiceImpl implements IRiskReportService 
{
    @Autowired
    private RiskReportMapper riskReportMapper;

    /**
     * 查询风险报告模块
     * 
     * @param reportId 风险报告模块主键
     * @return 风险报告模块
     */
    @Override
    public RiskReport selectRiskReportByReportId(Long reportId)
    {
        return riskReportMapper.selectRiskReportByReportId(reportId);
    }

    /**
     * 查询风险报告模块列表
     * 
     * @param riskReport 风险报告模块
     * @return 风险报告模块
     */
    @Override
    public List<RiskReport> selectRiskReportList(RiskReport riskReport)
    {
        return riskReportMapper.selectRiskReportList(riskReport);
    }

    /**
     * 新增风险报告模块
     * 
     * @param riskReport 风险报告模块
     * @return 结果
     */
    @Override
    public int insertRiskReport(RiskReport riskReport)
    {
        return riskReportMapper.insertRiskReport(riskReport);
    }

    /**
     * 修改风险报告模块
     * 
     * @param riskReport 风险报告模块
     * @return 结果
     */
    @Override
    public int updateRiskReport(RiskReport riskReport)
    {
        return riskReportMapper.updateRiskReport(riskReport);
    }

    /**
     * 批量删除风险报告模块
     * 
     * @param reportIds 需要删除的风险报告模块主键
     * @return 结果
     */
    @Override
    public int deleteRiskReportByReportIds(String reportIds)
    {
        return riskReportMapper.deleteRiskReportByReportIds(Convert.toStrArray(reportIds));
    }

    /**
     * 删除风险报告模块信息
     * 
     * @param reportId 风险报告模块主键
     * @return 结果
     */
    @Override
    public int deleteRiskReportByReportId(Long reportId)
    {
        return riskReportMapper.deleteRiskReportByReportId(reportId);
    }
}
